//================v1要点总结===============
/**
 * 爬楼梯
 * 递归，基本出不来，栈太多
 */


/**
 * @param {number} n
 * @return {number}
 */
 var climbStairs = function(n) {
    let rslt = 0
    function climb(rest){
        if(rest<0){
            return 
        }
        if(rest===0){
            rslt+=1
            return 
        }
        climb(rest-1)
        climb(rest-2)
    }
    climb(n)
    return rslt
};

console.log(climbStairs(44))